﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HCQ2_Model.Pay
{
    /// <summary>
    /// 购物车列表
    /// </summary>
    public class ShoppingList: IPayCommodityInfo, ISupplyType
    {
        /// <summary>
        /// 购物车ID
        /// </summary>
        public int ShoppingId { get; set; }

        /// <summary>
        /// 商品ID
        /// </summary>
        public int? CommodityId { get; set; }
        /// <summary>
        /// 文件略缩图地址
        /// </summary>
        public string FileImgUrl { get; set; }
        /// <summary>
        /// 别名
        /// </summary>
        public string AliasName { get; set; }
        /// <summary>
        /// 标题
        /// </summary>
        public string FileName { get; set; }
        /// <summary>
        /// 权限
        /// </summary>
        public string FolderLimit { get; set; }
        /// <summary>
        /// 简介
        /// </summary>
        public string FileNote { get; set; }
        /// <summary>
        /// 产品类别
        /// </summary>
        public string ProType { get; set; }
        /// <summary>
        /// 商品来源；0个人、1自营
        /// </summary>
        public int? SupplyType { get; set; }
        /// <summary>
        /// 商品类别
        /// </summary>
        public string PageType { get; set; }
        /// <summary>
        /// 格式
        /// </summary>
        public string Format { get; set; }
        /// <summary>
        /// 作者
        /// </summary>
        public string CreateFileUser { get; set; }
        /// <summary>
        /// 审核通过时间
        /// </summary>
        public string ApproveTime { get; set; }
        /// <summary>
        /// 时间
        /// </summary>
        public string CreateTime { get; set; }
        /// <summary>
        /// 价格
        /// </summary>
        public decimal CommodityMoney { get; set; }
        /// <summary>
        /// 期限;1（一个月）、3（三个月）、6（六个月）12（一年）
        /// </summary>
        public Nullable<int> PurchasePeriod { get; set; }
        /// <summary>
        /// 金额
        /// </summary>
        public decimal Price { get; set; }

        /// <summary>
        /// 文件大小
        /// </summary>
        public string FileSize { get; set; }


        #region 需求《VLions需求规格_度度圈接口需求_订单及购物车-202100909.docx》添加的内容

        /// <summary>
        /// 店铺ID
        /// </summary>
        public Nullable<int> StoreID { get; set; }

        /// <summary>
        /// 店铺名称
        /// </summary>
        public string StoreName { get; set; }

        /// <summary>
        /// 商品数量
        /// </summary>
        public int Quantity { get; set; }

        /// <summary>
        /// 下单类别；0=普通下单，1=扫码点餐下单
        /// </summary>
        public int OrderType { get; set; }

        #endregion

        /// <summary>
        /// 规格列表
        /// <br/>
        /// 2021-9-16：禅道170号需求添加<br/>
        /// </summary>
        public List<SpecParamModel> Specs { get; set; } = new List<SpecParamModel>();

        /// <summary>
        /// 是否售馨
        /// <br/>
        /// 2021-11-08：禅道215号需求添加
        /// </summary>
        public bool IsSoldOut { get; set; }

        /// <summary>
        /// 按商品规格获取的价格
        /// </summary>
        public decimal Cost { get; set; }

        /// <summary>
        /// 按商品规格获取的价格总金额= Cost * Quantity
        /// </summary>
        public decimal Amount { get; set; }
    }
}
